<html><body>
<style>

body, h1, h2, h3, div, span, p, pre, a {
  margin: 0;
  padding: 0;
  border: 0;
  font-weight: inherit;
  font-style: inherit;
  font-size: 100%;
  font-family: inherit;
  vertical-align: baseline;
}

body {
  font-size: 13px;
  padding: 1em;
}

h1 {
  font-size: 26px;
  margin-bottom: 1em;
}

h2 {
  font-size: 24px;
  margin-bottom: 1em;
}

h3 {
  font-size: 20px;
  margin-bottom: 1em;
  margin-top: 1em;
}

pre, code {
  line-height: 1.5;
  font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
}

pre {
  margin-top: 0.5em;
}

h1, h2, h3, p {
  font-family: Arial, sans serif;
}

h1, h2, h3 {
  border-bottom: solid #CCC 1px;
}

.toc_element {
  margin-top: 0.5em;
}

.firstline {
  margin-left: 2 em;
}

.method  {
  margin-top: 1em;
  border: solid 1px #CCC;
  padding: 1em;
  background: #EEE;
}

.details {
  font-weight: bold;
  font-size: 14px;
}

</style>

<h1><a href="androidpublisher_v3.html">Google Play Android Developer API</a> . <a href="androidpublisher_v3.monetization.html">monetization</a> . <a href="androidpublisher_v3.monetization.onetimeproducts.html">onetimeproducts</a> . <a href="androidpublisher_v3.monetization.onetimeproducts.purchaseOptions.html">purchaseOptions</a></h1>
<h2>Instance Methods</h2>
<p class="toc_element">
  <code><a href="androidpublisher_v3.monetization.onetimeproducts.purchaseOptions.offers.html">offers()</a></code>
</p>
<p class="firstline">Returns the offers Resource.</p>

<p class="toc_element">
  <code><a href="#batchDelete">batchDelete(packageName, productId, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Deletes purchase options across one or multiple one-time products. By default this operation will fail if there are any existing offers under the deleted purchase options. Use the force parameter to override the default behavior.</p>
<p class="toc_element">
  <code><a href="#batchUpdateStates">batchUpdateStates(packageName, productId, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Activates or deactivates purchase options across one or multiple one-time products.</p>
<p class="toc_element">
  <code><a href="#close">close()</a></code></p>
<p class="firstline">Close httplib2 connections.</p>
<h3>Method Details</h3>
<div class="method">
    <code class="details" id="batchDelete">batchDelete(packageName, productId, body=None, x__xgafv=None)</code>
  <pre>Deletes purchase options across one or multiple one-time products. By default this operation will fail if there are any existing offers under the deleted purchase options. Use the force parameter to override the default behavior.

Args:
  packageName: string, Required. The parent app (package name) of the purchase options to delete. (required)
  productId: string, Required. The product ID of the parent one-time product, if all purchase options to delete belong to the same one-time product. If this batch delete spans multiple one-time products, set this field to &quot;-&quot;. (required)
  body: object, The request body.
    The object takes the form of:

{ # Request message for BatchDeletePurchaseOption.
  &quot;requests&quot;: [ # Required. A list of delete requests of up to 100 elements. All requests must delete purchase options from different one-time products.
    { # Request message for deleting a purchase option.
      &quot;force&quot;: True or False, # Optional. This field has no effect for purchase options with no offers under them. For purchase options with associated offers: * If `force` is set to false (default), an error will be returned. * If `force` is set to true, any associated offers under the purchase option will be deleted.
      &quot;latencyTolerance&quot;: &quot;A String&quot;, # Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.
      &quot;packageName&quot;: &quot;A String&quot;, # Required. The parent app (package name) of the purchase option to delete.
      &quot;productId&quot;: &quot;A String&quot;, # Required. The parent one-time product (ID) of the purchase option to delete.
      &quot;purchaseOptionId&quot;: &quot;A String&quot;, # Required. The purchase option ID of the purchase option to delete.
    },
  ],
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format
</pre>
</div>

<div class="method">
    <code class="details" id="batchUpdateStates">batchUpdateStates(packageName, productId, body=None, x__xgafv=None)</code>
  <pre>Activates or deactivates purchase options across one or multiple one-time products.

Args:
  packageName: string, Required. The parent app (package name) of the updated purchase options. (required)
  productId: string, Required. The product ID of the parent one-time product, if all updated purchase options belong to the same one-time product. If this batch update spans multiple one-time products, set this field to &quot;-&quot;. (required)
  body: object, The request body.
    The object takes the form of:

{ # Request message for BatchUpdatePurchaseOptionStates.
  &quot;requests&quot;: [ # Required. The update request list of up to 100 elements. All requests must update different purchase options.
    { # Request message to update the state of a one-time product purchase option.
      &quot;activatePurchaseOptionRequest&quot;: { # Request message for UpdatePurchaseOptionState. # Activates a purchase option. Once activated, the purchase option will be available.
        &quot;latencyTolerance&quot;: &quot;A String&quot;, # Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.
        &quot;packageName&quot;: &quot;A String&quot;, # Required. The parent app (package name) of the purchase option to activate.
        &quot;productId&quot;: &quot;A String&quot;, # Required. The parent one-time product (ID) of the purchase option to activate.
        &quot;purchaseOptionId&quot;: &quot;A String&quot;, # Required. The purchase option ID of the purchase option to activate.
      },
      &quot;deactivatePurchaseOptionRequest&quot;: { # Request message for UpdatePurchaseOptionState. # Deactivates a purchase option. Once deactivated, the purchase option will become unavailable.
        &quot;latencyTolerance&quot;: &quot;A String&quot;, # Optional. The latency tolerance for the propagation of this product update. Defaults to latency-sensitive.
        &quot;packageName&quot;: &quot;A String&quot;, # Required. The parent app (package name) of the purchase option to deactivate.
        &quot;productId&quot;: &quot;A String&quot;, # Required. The parent one-time product (ID) of the purchase option to deactivate.
        &quot;purchaseOptionId&quot;: &quot;A String&quot;, # Required. The purchase option ID of the purchase option to deactivate.
      },
    },
  ],
}

  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # Response message for BatchUpdatePurchaseOptionStates.
  &quot;oneTimeProducts&quot;: [ # The list of updated one-time products. This list will match the requests one to one, in the same order.
    { # A single one-time product for an app.
      &quot;listings&quot;: [ # Required. Set of localized title and description data. Must not have duplicate entries with the same language_code.
        { # Regional store listing for a one-time product.
          &quot;description&quot;: &quot;A String&quot;, # Required. The description of this product in the language of this listing. The maximum length is 200 characters.
          &quot;languageCode&quot;: &quot;A String&quot;, # Required. The language of this listing, as defined by BCP-47, e.g., &quot;en-US&quot;.
          &quot;title&quot;: &quot;A String&quot;, # Required. The title of this product in the language of this listing. The maximum length is 55 characters.
        },
      ],
      &quot;offerTags&quot;: [ # Optional. List of up to 20 custom tags specified for this one-time product, and returned to the app through the billing library. Purchase options and offers for this product will also receive these tags in the billing library.
        { # Represents a custom tag specified for a product offer.
          &quot;tag&quot;: &quot;A String&quot;, # Must conform with RFC-1034. That is, this string can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-), and be at most 20 characters.
        },
      ],
      &quot;packageName&quot;: &quot;A String&quot;, # Required. Immutable. Package name of the parent app.
      &quot;productId&quot;: &quot;A String&quot;, # Required. Immutable. Unique product ID of the product. Unique within the parent app. Product IDs must start with a number or lowercase letter, and can contain numbers (0-9), lowercase letters (a-z), underscores (_), and periods (.).
      &quot;purchaseOptions&quot;: [ # Required. The set of purchase options for this one-time product.
        { # A single purchase option for a one-time product.
          &quot;buyOption&quot;: { # A purchase option that can be bought. # A purchase option that can be bought.
            &quot;legacyCompatible&quot;: True or False, # Optional. Whether this purchase option will be available in legacy PBL flows that do not support one-time products model. Up to one &quot;buy&quot; purchase option can be marked as backwards compatible.
            &quot;multiQuantityEnabled&quot;: True or False, # Optional. Whether this purchase option allows multi-quantity. Multi-quantity allows buyer to purchase more than one item in a single checkout.
          },
          &quot;newRegionsConfig&quot;: { # Pricing information for any new regions Play may launch in the future. # Pricing information for any new locations Play may launch in the future. If omitted, the purchase option will not be automatically available in any new locations Play may launch in the future.
            &quot;availability&quot;: &quot;A String&quot;, # Required. The regional availability for the new regions config. When set to AVAILABLE, the pricing information will be used for any new regions Play may launch in the future.
            &quot;eurPrice&quot;: { # Represents an amount of money with its currency type. # Required. Price in EUR to use for any new regions Play may launch in.
              &quot;currencyCode&quot;: &quot;A String&quot;, # The three-letter currency code defined in ISO 4217.
              &quot;nanos&quot;: 42, # Number of nano (10^-9) units of the amount. The value must be between -999,999,999 and +999,999,999 inclusive. If `units` is positive, `nanos` must be positive or zero. If `units` is zero, `nanos` can be positive, zero, or negative. If `units` is negative, `nanos` must be negative or zero. For example $-1.75 is represented as `units`=-1 and `nanos`=-750,000,000.
              &quot;units&quot;: &quot;A String&quot;, # The whole units of the amount. For example if `currencyCode` is `&quot;USD&quot;`, then 1 unit is one US dollar.
            },
            &quot;usdPrice&quot;: { # Represents an amount of money with its currency type. # Required. Price in USD to use for any new regions Play may launch in.
              &quot;currencyCode&quot;: &quot;A String&quot;, # The three-letter currency code defined in ISO 4217.
              &quot;nanos&quot;: 42, # Number of nano (10^-9) units of the amount. The value must be between -999,999,999 and +999,999,999 inclusive. If `units` is positive, `nanos` must be positive or zero. If `units` is zero, `nanos` can be positive, zero, or negative. If `units` is negative, `nanos` must be negative or zero. For example $-1.75 is represented as `units`=-1 and `nanos`=-750,000,000.
              &quot;units&quot;: &quot;A String&quot;, # The whole units of the amount. For example if `currencyCode` is `&quot;USD&quot;`, then 1 unit is one US dollar.
            },
          },
          &quot;offerTags&quot;: [ # Optional. List of up to 20 custom tags specified for this purchase option, and returned to the app through the billing library. Offers for this purchase option will also receive these tags in the billing library.
            { # Represents a custom tag specified for a product offer.
              &quot;tag&quot;: &quot;A String&quot;, # Must conform with RFC-1034. That is, this string can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-), and be at most 20 characters.
            },
          ],
          &quot;purchaseOptionId&quot;: &quot;A String&quot;, # Required. Immutable. The unique identifier of this purchase option. Must be unique within the one-time product. It must start with a number or lower-case letter, and can only contain lower-case letters (a-z), numbers (0-9), and hyphens (-). The maximum length is 63 characters.
          &quot;regionalPricingAndAvailabilityConfigs&quot;: [ # Regional pricing and availability information for this purchase option.
            { # Regional pricing and availability configuration for a purchase option.
              &quot;availability&quot;: &quot;A String&quot;, # The availability of the purchase option.
              &quot;price&quot;: { # Represents an amount of money with its currency type. # The price of the purchase option in the specified region. Must be set in the currency that is linked to the specified region.
                &quot;currencyCode&quot;: &quot;A String&quot;, # The three-letter currency code defined in ISO 4217.
                &quot;nanos&quot;: 42, # Number of nano (10^-9) units of the amount. The value must be between -999,999,999 and +999,999,999 inclusive. If `units` is positive, `nanos` must be positive or zero. If `units` is zero, `nanos` can be positive, zero, or negative. If `units` is negative, `nanos` must be negative or zero. For example $-1.75 is represented as `units`=-1 and `nanos`=-750,000,000.
                &quot;units&quot;: &quot;A String&quot;, # The whole units of the amount. For example if `currencyCode` is `&quot;USD&quot;`, then 1 unit is one US dollar.
              },
              &quot;regionCode&quot;: &quot;A String&quot;, # Required. Region code this configuration applies to, as defined by ISO 3166-2, e.g., &quot;US&quot;.
            },
          ],
          &quot;rentOption&quot;: { # A purchase option that can be rented. # A purchase option that can be rented.
            &quot;expirationPeriod&quot;: &quot;A String&quot;, # Optional. The amount of time the user has after starting consuming the entitlement before it is revoked. Specified in ISO 8601 format.
            &quot;rentalPeriod&quot;: &quot;A String&quot;, # Required. The amount of time a user has the entitlement for. Starts at purchase flow completion. Specified in ISO 8601 format.
          },
          &quot;state&quot;: &quot;A String&quot;, # Output only. The state of the purchase option, i.e., whether it&#x27;s active. This field cannot be changed by updating the resource. Use the dedicated endpoints instead.
          &quot;taxAndComplianceSettings&quot;: { # Details about taxation, Google Play policy and legal compliance for one-time product purchase options. # Optional. Details about taxes and legal compliance.
            &quot;withdrawalRightType&quot;: &quot;A String&quot;, # Optional. Digital content or service classification for products distributed to users in eligible regions. If unset, it defaults to `WITHDRAWAL_RIGHT_DIGITAL_CONTENT`. Refer to the [Help Center article](https://support.google.com/googleplay/android-developer/answer/10463498) for more information.
          },
        },
      ],
      &quot;regionsVersion&quot;: { # The version of the available regions being used for the specified resource. # Output only. The version of the regions configuration that was used to generate the one-time product.
        &quot;version&quot;: &quot;A String&quot;, # Required. A string representing the version of available regions being used for the specified resource. Regional prices and latest supported version for the resource have to be specified according to the information published in [this article](https://support.google.com/googleplay/android-developer/answer/10532353). Each time the supported locations substantially change, the version will be incremented. Using this field will ensure that creating and updating the resource with an older region&#x27;s version and set of regional prices and currencies will succeed even though a new version is available.
      },
      &quot;restrictedPaymentCountries&quot;: { # Countries where the purchase of this product is restricted to payment methods registered in the same country. If empty, no payment location restrictions are imposed. # Optional. Countries where the purchase of this one-time product is restricted to payment methods registered in the same country. If empty, no payment location restrictions are imposed.
        &quot;regionCodes&quot;: [ # Required. Region codes to impose payment restrictions on, as defined by ISO 3166-2, e.g. &quot;US&quot;.
          &quot;A String&quot;,
        ],
      },
      &quot;taxAndComplianceSettings&quot;: { # Details about taxation, Google Play policy and legal compliance for one-time products. # Details about taxes and legal compliance.
        &quot;isTokenizedDigitalAsset&quot;: True or False, # Whether this one-time product is declared as a product representing a tokenized digital asset.
        &quot;regionalTaxConfigs&quot;: [ # Regional tax configuration.
          { # Details about taxation in a given geographical region.
            &quot;eligibleForStreamingServiceTaxRate&quot;: True or False, # You must tell us if your app contains streaming products to correctly charge US state and local sales tax. Field only supported in the United States.
            &quot;regionCode&quot;: &quot;A String&quot;, # Required. Region code this configuration applies to, as defined by ISO 3166-2, e.g. &quot;US&quot;.
            &quot;streamingTaxType&quot;: &quot;A String&quot;, # To collect communications or amusement taxes in the United States, choose the appropriate tax category. [Learn more](https://support.google.com/googleplay/android-developer/answer/10463498#streaming_tax).
            &quot;taxTier&quot;: &quot;A String&quot;, # Tax tier to specify reduced tax rate. Developers who sell digital news, magazines, newspapers, books, or audiobooks in various regions may be eligible for reduced tax rates. [Learn more](https://support.google.com/googleplay/android-developer/answer/10463498).
          },
        ],
      },
    },
  ],
}</pre>
</div>

<div class="method">
    <code class="details" id="close">close()</code>
  <pre>Close httplib2 connections.</pre>
</div>

</body></html>